home *** CD-ROM | disk | FTP | other *** search
/ PC World Komputer 2010 April / PCWorld0410.iso / hity wydania / Ubuntu 9.10 PL / karmelkowy-koliberek-desktop-9.10-i386-PL.iso / casper / filesystem.squashfs / lib / partman / init.d / 03kernelmodules_ext3 < prev    next >
Text File  |  2009-10-28  |  662b  |  34 lines

  1. #!/bin/sh
  2.  
  3. mkdir -p /var/lib/partman
  4.  
  5. cat /proc/modules |
  6. while read module_name x; do
  7.     if [ "$module_name" = ext3 ]; then
  8.         >/var/lib/partman/ext3
  9.     fi
  10.     if [ "$module_name" = ext4 ]; then
  11.         >/var/lib/partman/ext4
  12.     fi
  13. done
  14.  
  15. if ! [ -f /var/lib/partman/ext3 ] && \
  16.    modprobe ext3 >/dev/null 2>/dev/null; then
  17.     >/var/lib/partman/ext3
  18. fi
  19.  
  20. if ! [ -f /var/lib/partman/ext4 ] && \
  21.    modprobe ext4 >/dev/null 2>/dev/null; then
  22.     >/var/lib/partman/ext4
  23. fi
  24.  
  25. if ! [ -f /var/lib/partman/ext3 ] && \
  26.    grep -q ext3 /proc/filesystems; then
  27.     >/var/lib/partman/ext3
  28. fi
  29.  
  30. if ! [ -f /var/lib/partman/ext4 ] && \
  31.    grep -q ext4 /proc/filesystems; then
  32.     >/var/lib/partman/ext4
  33. fi
  34.